:root {
    --primary-color: #ff6b6b;
    --secondary-color: #4ecdc4;
    --background-color: #2f3542;
    --text-color: #f1f2f6;
}

body {
    margin: 0;
    padding: 0;
    font-family: 'Arial', sans-serif;
    background-color: var(--background-color);
    color: var(--text-color);
}

.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.2rem 4rem;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    position: fixed;
    width: 100%;
    top: 0;
    left: 0;
    z-index: 1000;
    box-sizing: border-box;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
}

.logo {
    display: flex;
    align-items: center;
}

.logo h1 {
    margin: 0;
    font-size: 2rem;
    color: var(--text-color);
    font-weight: 700;
    letter-spacing: 1px;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
}

.nav {
    display: flex;
    gap: 2.5rem;
    align-items: center;
}

.nav-item {
    color: var(--text-color);
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    transition: all 0.3s ease;
    position: relative;
    opacity: 0.8;
}

.nav-item:hover {
    opacity: 1;
    transform: translateY(-2px);
}

.nav-item.active {
    color: var(--primary-color);
    opacity: 1;
}

.nav-item.active::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 50%;
    transform: translateX(-50%);
    width: 25px;
    height: 2px;
    background: var(--primary-color);
    border-radius: 2px;
    box-shadow: 0 0 10px var(--primary-color);
}

.login-btn {
    padding: 0.8rem 2rem;
    border: 2px solid var(--primary-color);
    border-radius: 25px;
    background: transparent;
    color: var(--text-color);
    cursor: pointer;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s ease;
    margin-left: 2rem;
    letter-spacing: 1px;
}

.login-btn:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(255, 107, 107, 0.5);
}

.hero-section {
    margin-top: 70px;
    position: relative;
    height: 100vh;
    background: linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0.2),
        rgba(0, 0, 0, 0.4)
    ),
    url('hero-bg.jpg') center/cover;
    overflow: hidden;
}

/* 修改背景渐变效果 */
.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 50%, rgba(255, 196, 107, 0.2) 0%, transparent 50%),
        radial-gradient(circle at 80% 50%, rgba(78, 205, 196, 0.2) 0%, transparent 50%);
    animation: pulse 12s ease-in-out infinite alternate;
}

.hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
    padding: 2rem;
    max-width: 800px;
    margin: 0 auto;
    margin-top: 15vh;
}

.hero-content h1 {
    font-size: 5rem;
    margin-bottom: 1.5rem;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.5);
    color: #fff;
    font-weight: 700;
    letter-spacing: 2px;
}

.hero-subtitle {
    font-size: 1.5rem;
    margin-bottom: 2rem;
    color: #fff;
    text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.5);
    opacity: 0;
    animation: fadeInUp 1s ease-out 0.5s forwards;
}

/* 添加装饰元素 */
.hero-decoration {
    position: absolute;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.hero-decoration::before,
.hero-decoration::after {
    content: '';
    position: absolute;
    width: 300px;
    height: 300px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    filter: blur(40px);
}

.hero-decoration::before {
    top: -100px;
    left: -100px;
}

.hero-decoration::after {
    bottom: -100px;
    right: -100px;
}

/* 动画关键帧 */
@keyframes pulse {
    0% {
        opacity: 0.6;
        transform: scale(1);
    }
    100% {
        opacity: 1;
        transform: scale(1.1);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 按钮悬停效果 */
.primary-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 107, 107, 0.4);
}

.secondary-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 107, 107, 0.2);
}

.game-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    padding: 2rem;
}

.game-card {
    background: rgba(255,255,255,0.1);
    border-radius: 15px;
    overflow: hidden;
    transition: transform 0.3s ease;
}

.game-card:hover {
    transform: translateY(-5px);
}

.card-image img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.rating {
    padding: 0.5rem;
    color: var(--primary-color);
}

.card-content {
    padding: 1rem;
}

.primary-btn, .secondary-btn {
    padding: 0.8rem 2rem;
    border: none;
    border-radius: 25px;
    font-weight: bold;
    cursor: pointer;
    transition: transform 0.2s ease;
    text-decoration: none;
    display: inline-block;
}

.primary-btn {
    background-color: var(--primary-color);
    color: white;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    font-size: 1.1rem;
    padding: 1rem 2.5rem;
}

.secondary-btn {
    background-color: transparent;
    border: 2px solid rgba(255, 255, 255, 0.9);
    color: rgba(255, 255, 255, 0.9);
    padding: 1rem 2.5rem;
    font-size: 1.1rem;
}

/* 添加海鸟动画效果 */
.birds {
    position: absolute;
    top: 20%;
    left: -100px;
    width: 100px;
    height: 50px;
    background: url('birds-silhouette.png') no-repeat;
    background-size: contain;
    opacity: 0.6;
    animation: flyBirds 20s linear infinite;
}

@keyframes flyBirds {
    from {
        transform: translateX(-100px);
    }
    to {
        transform: translateX(calc(100vw + 100px));
    }
}

/* 添加云彩飘动效果 */
.clouds {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        url('clouds.png') repeat-x;
    opacity: 0.3;
    animation: moveClouds 60s linear infinite;
}

@keyframes moveClouds {
    from {
        background-position: 0 0;
    }
    to {
        background-position: 100% 0;
    }
}

/* 登录按钮样式 */
.login-btn {
    background-color: transparent;
    border: 2px solid var(--text-color);
    color: var(--text-color);
    padding: 0.5rem 1.5rem;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.login-btn:hover {
    background-color: var(--text-color);
    color: var(--background-color);
}

/* 登录弹窗样式 */
.login-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    backdrop-filter: blur(5px);
}

.login-modal.active {
    display: flex;
    animation: fadeIn 0.3s ease;
}

.login-container {
    background-color: white;
    width: 90%;
    max-width: 400px;
    margin: auto;
    padding: 2rem;
    border-radius: 15px;
    position: relative;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
    animation: slideUp 0.4s ease;
}

.close-btn {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #666;
}

.login-container h2 {
    color: var(--background-color);
    text-align: center;
    margin-bottom: 2rem;
}

.form-group {
    position: relative;
    margin-bottom: 1.5rem;
}

.form-group input {
    width: 100%;
    padding: 0.8rem;
    border: 1px solid #ddd;
    border-radius: 8px;
    outline: none;
    transition: all 0.3s ease;
}

.form-group label {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: #999;
    transition: all 0.3s ease;
    pointer-events: none;
}

.form-group input:focus + label,
.form-group input:valid + label {
    top: 0;
    left: 0.8rem;
    font-size: 0.8rem;
    padding: 0 0.4rem;
    background: white;
}

.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.remember-me {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #666;
}

.forgot-password {
    color: var(--primary-color);
    text-decoration: none;
    font-size: 0.9rem;
}

.login-submit-btn {
    width: 100%;
    padding: 1rem;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.3s ease;
}

.login-submit-btn:hover {
    background-color: darken(var(--primary-color), 10%);
}

.register-link {
    text-align: center;
    margin-top: 1.5rem;
    color: #666;
}

.register-link a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: bold;
}

/* 动画效果 */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* 注册弹窗样式 */
.register-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    backdrop-filter: blur(5px);
}

.register-modal.active {
    display: flex;
    animation: fadeIn 0.3s ease;
}

.register-container {
    background-color: white;
    width: 90%;
    max-width: 400px;
    margin: auto;
    padding: 2rem;
    border-radius: 15px;
    position: relative;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
    animation: slideUp 0.4s ease;
}

.register-submit-btn {
    width: 100%;
    padding: 1rem;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.3s ease;
}

.register-submit-btn:hover {
    background-color: darken(var(--primary-color), 10%);
}

.agree-terms {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    color: #666;
    font-size: 0.9rem;
}

.agree-terms input[type="checkbox"] {
    margin-top: 0.2rem;
}

.terms-link, .privacy-link {
    color: var(--primary-color);
    text-decoration: none;
}

.terms-link:hover, .privacy-link:hover {
    text-decoration: underline;
}

.login-link {
    text-align: center;
    margin-top: 1.5rem;
    color: #666;
}

.login-link a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: bold;
}

/* 密码强度指示器 */
.password-strength {
    height: 4px;
    background-color: #eee;
    margin-top: 0.5rem;
    border-radius: 2px;
    overflow: hidden;
}

.strength-meter {
    height: 100%;
    width: 0;
    transition: all 0.3s ease;
}

.strength-weak {
    background-color: #ff4d4d;
    width: 33.33%;
}

.strength-medium {
    background-color: #ffd700;
    width: 66.66%;
}

.strength-strong {
    background-color: #00cc00;
    width: 100%;
}

/* 手机号验证码组 */
.phone-group {
    position: relative;
}

.send-code-btn {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    padding: 0.5rem 1rem;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.send-code-btn:disabled {
    background-color: #ccc;
    cursor: not-allowed;
}

.send-code-btn.counting {
    background-color: #888;
}

/* 图形验证码组 */
.captcha-group {
    position: relative;
}

.captcha-wrapper {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

#captchaImage {
    height: 38px;
    border-radius: 4px;
    cursor: pointer;
}

.refresh-captcha {
    background: none;
    border: none;
    color: #666;
    cursor: pointer;
    padding: 0.5rem;
    transition: transform 0.3s ease;
}

.refresh-captcha:hover {
    transform: rotate(180deg);
}

/* 调整输入框padding以适应按钮 */
.phone-group input,
.captcha-group input {
    padding-right: 120px;
}

.register-container h2 {
    color: var(--background-color);
    text-align: center;
    margin-bottom: 2rem;
    font-size: 1.8rem;
    font-weight: 600;
    color: #333;
    text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.1);
}

/* 确保链接形式的按钮和普通按钮样式一致 */
a.primary-btn:hover {
    color: white;
    text-decoration: none;
}

/* 适配移动端 */
@media (max-width: 768px) {
    .header {
        padding: 1rem 2rem;
    }

    .logo h1 {
        font-size: 1.5rem;
    }

    .nav {
        gap: 1.5rem;
    }

    .nav-item {
        font-size: 1rem;
        padding: 0.4rem 0.8rem;
    }

    .login-btn {
        padding: 0.6rem 1.5rem;
        margin-left: 1rem;
    }
} 